package org.example.controller;

import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import reactor.core.publisher.Flux;

@Tag(name = "WebFlux 演示", description = "Spring WebFlux 响应式接口示例")
@RestController
@RequestMapping("/flux")
public class FluxDemoController {
    @Operation(summary = "获取字符串流", description = "返回一个字符串的响应式流")
    @GetMapping("/strings")
    public Flux<String> getStrings() {
        return Flux.just("A", "B", "C", "D");
    }
} 